Application scheduling at a communications device is typically based on an underlying onboard operating system (OS). Due to the time-sensitive nature, real-time OSs such as VxWork are often used in communication devices such as an IP router to ensure central tasks such as packet routing are done in a way that meets real-time requirements. These requirements may include, for example, guaranteed throughput, packet delay, delay variation and jitter, among others.
There are typically two general approaches to application scheduling commonly found in real time OS and general-purpose OSs. One is an interrupt-based scheduling and the other is a polling based scheduling. For an interrupt-based approach, every time an event occurs that needs processing, an OS interrupt is generated to wake up a task to process the event. Otherwise, the assigned task is in a waiting state and does not take up any CPU cycle. On the other hand, the polling based system typically assigns a highest priority to a dedicated task, referred to as the polling task, and the polling task is assigned a high percentage of CPU cycles and has the privilege to preempt any other lower-priority tasks to ensure that a critical job is done in a way that meets the real-time requirements.
The priority-based polling approach to application scheduling is commonly found in real-time OSs. In this approach, a high-priority polling task can be dedicated to a critical function such as packet forwarding in an attempt to achieve real-time requirements.
A task in an application scheduling system refers to an application or process that has been loaded into the operating system and is either being executed or waiting in a task queue to be executed. In a priority-based application scheduling system, a task has an assigned priority that determines its position in a waiting queue relative to other tasks. The term task scheduling and the term application schedule are used interchangeably in the present disclosure, unless otherwise specified.